package com.geekstudy.week8.hmily;

import org.dromara.hmily.common.enums.HmilyRoleEnum;
import org.dromara.hmily.core.service.AbstractHmilyTransactionHandlerFactory;
import org.dromara.hmily.core.service.HmilyTransactionHandler;
import org.dromara.hmily.spi.HmilySPI;
import org.dromara.hmily.tcc.handler.LocalHmilyTccTransactionHandler;
import org.dromara.hmily.tcc.handler.ParticipantHmilyTccTransactionHandler;
import org.dromara.hmily.tcc.handler.StarterHmilyTccTransactionHandler;

import java.util.Map;

@HmilySPI("tcc")
public class HmilyTccTransactionHandlerRegistry extends AbstractHmilyTransactionHandlerFactory {


    @Override
    protected Map<HmilyRoleEnum, HmilyTransactionHandler> getMap() {
        // getHandlers().put(HmilyRoleEnum.START, new StarterHmilyTccTransactionHandler());
        // getHandlers().put(HmilyRoleEnum.PARTICIPANT, new ParticipantHmilyTccTransactionHandler());
        // getHandlers().put(HmilyRoleEnum.CONSUMER, new ParticipantHmilyTccTransactionHandler());
        // getHandlers().put(HmilyRoleEnum.LOCAL, new LocalHmilyTccTransactionHandler());

        return null;
    }
}
